typedef unsigned long MSIHANDLE;     // abstract generic handle, 0 == no handle

/* In pginstca.c */
int MsgBox(int param, WCHAR *title, WCHAR *fmt, ...);
WCHAR *lasterror_string();

/* In user.c */
extern BOOL CheckUserExists(LPTSTR szDomain, LPTSTR szUser);
extern BOOL CreateUser(LPTSTR szDomain, LPTSTR szUser, LPTSTR szPassword, WCHAR *errbuf, DWORD errsize);
extern BOOL CheckUserPrivileges(LPTSTR szDomain, LPTSTR szUser, BOOL noprompt, WCHAR *errbuf, DWORD errsize);
extern BOOL CheckUserIsAdmin(HANDLE token, WCHAR *errbuf, DWORD errsize);
extern BOOL CheckUserIsLocalAdmin(LPTSTR szDomain, LPTSTR szUser, WCHAR *errbuf, DWORD errsize);
extern int is_running_as_local_system(char *errbuf, int errbufsize);

/* In sspi.c */
extern char _sspi_error[256];
extern BOOL WINAPI SSPLogonUser(LPTSTR szDomain, LPTSTR szUser, LPTSTR szPassword, WCHAR *errbuf, DWORD errsize);


/* In lang.c */
#define __(t) pginst_gettext(L ## t)
extern WCHAR *pginst_gettext(const WCHAR *t);
extern void pginst_settext(MSIHANDLE h);
extern void pginst_settext2(char *langid);

/* In pgcontrol.c */
int CheckPgControl(FILE *f);
